package com.china.lottery.listener.dao.entity;

import javax.persistence.*;

import java.io.Serializable;
import java.util.Date;

/**
 * Created by tongzhaobin on 14-10-2.
 */

@Entity
@Table(name = "L_CHANNEL_BET_SWITCH")
public class LChannelBetSwitch implements Serializable {

    private static final long serialVersionUID = 1L;
    private Integer id;
    private String agentId;
    private String lotteryCode;
    private String lotteryName;
    private Boolean isOpened;
    private String betchannelCode;
    private String betchannelName;
    private String channelBeanName;
    private Date createTime;
    private Date updateTime;
    private int isSpareChannel;
	private String betchannelCodes;

    @Id
    @SequenceGenerator(name="S_CHANNEL_BET_SWITCH_GENERATOR", sequenceName="S_CHANNEL_BET_SWITCH",allocationSize=1)
    @GeneratedValue(strategy=GenerationType.SEQUENCE, generator="S_CHANNEL_BET_SWITCH_GENERATOR")
    public Integer getId() {
        return this.id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    @Column(name = "AGENT_ID", nullable = false, length = 30)
    public String getAgentId() {
        return this.agentId;
    }

    public void setAgentId(String agentId) {
        this.agentId = agentId;
    }

    @Column(name = "LOTTERY_CODE", nullable = false, length = 20)
    public String getLotteryCode() {
        return this.lotteryCode;
    }

    public void setLotteryCode(String lotteryCode) {
        this.lotteryCode = lotteryCode;
    }

    @Column(name = "LOTTERY_NAME", length = 50)
    public String getLotteryName() {
        return this.lotteryName;
    }

    public void setLotteryName(String lotteryName) {
        this.lotteryName = lotteryName;
    }

    @Column(name = "IS_OPENED", nullable = false, precision = 1, scale = 0)
    public Boolean getIsOpened() {
        return this.isOpened;
    }

    public void setIsOpened(Boolean isOpened) {
        this.isOpened = isOpened;
    }

    @Column(name = "BETCHANNEL_CODE", nullable = false, length = 10)
    public String getBetchannelCode() {
        return this.betchannelCode;
    }

    public void setBetchannelCode(String betchannelCode) {
        this.betchannelCode = betchannelCode;
    }

    @Column(name = "BETCHANNEL_NAME", length = 60)
    public String getBetchannelName() {
        return this.betchannelName;
    }

    public void setBetchannelName(String betchannelName) {
        this.betchannelName = betchannelName;
    }

    @Column(name = "CHANNEL_BEAN_NAME", nullable = false, length = 500)
    public String getChannelBeanName() {
        return this.channelBeanName;
    }

    public void setChannelBeanName(String channelBeanName) {
        this.channelBeanName = channelBeanName;
    }

    @Column(name = "CREATE_TIME")
    public Date getCreateTime() {
        return this.createTime;
    }

    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }

    @Temporal(TemporalType.TIMESTAMP)
    @Column(name = "UPDATE_TIME")
    public Date getUpdateTime() {
        return this.updateTime;
    }

    public void setUpdateTime(Date updateTime) {
        this.updateTime = updateTime;
    }

	@Column(name = "IS_SPARE_CHANNEL", precision = 2, scale = 0)
	public int getIsSpareChannel() {
		return isSpareChannel;
	}

	public void setIsSpareChannel(int isSpareChannel) {
		this.isSpareChannel = isSpareChannel;
	}

	@Column(name = "BETCHANNEL_CODES", length = 10)
	public String getBetchannelCodes() {
		return betchannelCodes;
	}

	public void setBetchannelCodes(String betchannelCodes) {
		this.betchannelCodes = betchannelCodes;
	}
	
    @Override
    public String toString() {
        return "LChannelBetSwitch{" +
                "id=" + id +
                ", agentId='" + agentId + '\'' +
                ", lotteryCode='" + lotteryCode + '\'' +
                ", lotteryName='" + lotteryName + '\'' +
                ", isOpened=" + isOpened +
                ", betchannelCode='" + betchannelCode + '\'' +
                ", betchannelName='" + betchannelName + '\'' +
                ", channelBeanName='" + channelBeanName + '\'' +
                ", createTime=" + createTime +
                ", updateTime=" + updateTime +
                '}';
    }
}
